// 全局注册组件
import PageTool from '@/components/PageTool'
import UploadExcel from '@/components/UploadExcel'
import UploadImg from '@/components/UploadImg'
import ImageHolder from '@/components/ImageHolder'
import Lang from '@/components/Lang'
import ScreenFull from '@/components/ScreenFull'

// 1.定义插件(拓展Vue的功能)
const MyPlugin = {
  install(Vue) {
    Vue.component(PageTool.name, PageTool)
    Vue.component(UploadExcel.name, UploadExcel)
    Vue.component(UploadImg.name, UploadImg)
    Vue.component(ImageHolder.name, ImageHolder)
    Vue.component(Lang.name, Lang)
    Vue.component(ScreenFull.name, ScreenFull)

    // console.log('插件注册，调用install，传入的参数是', Vue)
    // // 在Vue的构造器的原型上添加功能
    // Vue.prototype.$abc = () => { console.log('abc') }
    // 添加全局过滤器/组件/指令
  }
}
export default MyPlugin
